<?php
/**
 * Created by PhpStorm.
 * User: 王鹏飞
 * Date: 2018/4/19
 * Time: 22:28
 */

namespace User\Model;
use Think\Model\RelationModel;
class UserinfoModel extends RelationModel
{
    protected $_link = array(
        'cardlevel' => array(
            'mapping_type' => self::BELONGS_TO,
        // 'class_name' => 'cardlevel',
       //   'parent_key' =>'cardlevel',
           'foreign_key'=> 'cardlevel',
            'mapping_fields'  => 'cardname',
            'as_fields' => 'cardname'
        )
    );

}